cmake_minimum_required(VERSION 3.8)
project(string_comparison)

set(var1 "Hi")
#set(var2 "Hello")
set(var2 "Hi")

string(COMPARE LESS ${var1} ${var2} out1)
string(COMPARE GREATER ${var1} ${var2} out2)
string(COMPARE EQUAL ${var1} ${var2} out3)
string(COMPARE NOTEQUAL ${var1} ${var2} out4)
string(COMPARE LESS_EQUAL ${var1} ${var2} out5)
string(COMPARE GREATER_EQUAL ${var1} ${var2} out6)

message(STATUS "LESS -- ${out1}")
message(STATUS "GREATER -- ${out2}")
message(STATUS "EQUAL -- ${out3}")
message(STATUS "NOTEQUAL -- ${out4}")
message(STATUS "LESS_EQUAL -- ${out5}")
message(STATUS "GREATER_EQUAL -- ${out6}")
